package com.robot.member.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * consumption实体类
 * @author lin
 *
 */
@Entity
@Table(name="consumption")
public class Consumption implements Serializable{
	/**
	 *id
	 */
	@Id
	private String id;
	/**
	 *会员id
	 */
	private String memberId;
	/**
	 *会员名字
	 */
	private String memberName;
	/**
	 *店铺/商家id
	 */
	private String storeId;
	/**
	 *店铺/商家名称
	 */
	private String storeName;
	/**
	 *区域id,用于查询代理商
	 */
	private String areaId;
	/**
	 *金豆数量
	 */
	private Integer goldenBeans;
	/**
	 *码豆数量
	 */
	private Integer beans;
	/**
	 *会员积分数量
	 */
	private Integer memberPoints;
	/**
	 *0-获得 1-消费
	 */
	private String type;
	/**
	 *备注
	 */
	private String remark;
	/**
	 * 创建时间
	 */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime createdAt;
	/**
	 * 最后更新时间
	 */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime updatedAt;
	/**
	 * 删除时间
	 */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime deletedAt;


	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}

	public String getMemberId() {
		return memberId;
	}
	public void setMemberId(String memberId) {
		this.memberId = memberId;
	}

	public String getMemberName() {
		return memberName;
	}
	public void setMemberName(String memberName) {
		this.memberName = memberName;
	}

	public String getStoreId() {
		return storeId;
	}
	public void setStoreId(String storeId) {
		this.storeId = storeId;
	}

	public String getStoreName() {
		return storeName;
	}
	public void setStoreName(String storeName) {
		this.storeName = storeName;
	}

	public String getAreaId() {
		return areaId;
	}
	public void setAreaId(String areaId) {
		this.areaId = areaId;
	}

	public Integer getGoldenBeans() {
		return goldenBeans;
	}
	public void setGoldenBeans(Integer goldenBeans) {
		this.goldenBeans = goldenBeans;
	}

	public Integer getBeans() {
		return beans;
	}
	public void setBeans(Integer beans) {
		this.beans = beans;
	}

	public Integer getMemberPoints() {
		return memberPoints;
	}
	public void setMemberPoints(Integer memberPoints) {
		this.memberPoints = memberPoints;
	}

	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}

	public String getRemark() {
		return remark;
	}
	public void setRemark(String remark) {
		this.remark = remark;
	}

	public LocalDateTime getCreatedAt() {
		return createdAt;
	}

	public void setCreatedAt(LocalDateTime createdAt) {
		this.createdAt = createdAt;
	}

	public LocalDateTime getUpdatedAt() {
		return updatedAt;
	}

	public void setUpdatedAt(LocalDateTime updatedAt) {
		this.updatedAt = updatedAt;
	}

	public LocalDateTime getDeletedAt() {
		return deletedAt;
	}

	public void setDeletedAt(LocalDateTime deletedAt) {
		this.deletedAt = deletedAt;
	}

	@Override
	public String toString() {
		return "Consumption{" +
				"id='" + id + '\'' +
				", memberId='" + memberId + '\'' +
				", memberName='" + memberName + '\'' +
				", storeId='" + storeId + '\'' +
				", storeName='" + storeName + '\'' +
				", areaId='" + areaId + '\'' +
				", goldenBeans=" + goldenBeans +
				", beans=" + beans +
				", memberPoints=" + memberPoints +
				", type='" + type + '\'' +
				", remark='" + remark + '\'' +
				", createdAt=" + createdAt +
				", updatedAt=" + updatedAt +
				", deletedAt=" + deletedAt +
				'}';
	}
}
